<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <title>Document</title>
        <style>
            * {
                margin: 0; padding: 0;
            }
            html,body {
                    width: 100%; height: 100%;
            }
            ul {
                margin: 100px auto;
                width: 200px; height: 200px;
                overflow: hidden;
            }
            ul>li {
                width: 200px; height: 200px;
                color: bisque;
                font: 100px/200px "楷体";
                background-color: black;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <ul>
            <li style="margin-top:0px;">今</li>
            <li>朝</li>
            <li>葬</li>
            <li>花</li>
            <li>侬</li>
            <li>笑</li>
            <li>痴</li>
            <li>,</li>
            <li>他</li>
            <li>年</li>
            <li>葬</li>
            <li>侬</li>
            <li>知</li>
            <li>是</li>
            <li>谁</li>
            <li>今</li>
        </ul>
        <script>
            setInterval(function(){
                var liObj = document.querySelector('li:nth-child(1)')
                // console.log(liObj);
                
                var xxx = parseInt(liObj.style.marginTop)
                xxx-=5
                liObj.style.marginTop = xxx+'px'
                if(xxx == -3000) {
                    liObj.style.marginTop = 0+'px'
                }
            },10)
        </script>
    </body>
</html>